<template>
  <el-row>
    <el-col :span="12">

      <el-menu default-active="2" class="el-menu-vertical-demo tac" @open="handleOpen" @close="handleClose"
        :collapse-transition="true" :router="true">
        <el-menu-item index="/login">
          <el-icon><icon-menu /></el-icon>
          <span>首页</span>
        </el-menu-item>
        <el-menu-item index="/vedio">
          <el-icon>
            <StarFilled />
          </el-icon>
          <span>推荐</span>
        </el-menu-item>
        <el-menu-item index="3">
          <el-icon>
            <document />
          </el-icon>
          <span>Navigator</span>
        </el-menu-item>
        <el-menu-item index="4">
          <el-icon>
            <User />
          </el-icon>
          <span>个人中心</span>
        </el-menu-item>
      </el-menu>
    </el-col>

  </el-row>
</template>

<script lang="ts" setup>
import {
  Document,
  Menu as IconMenu,
  User,
} from '@element-plus/icons-vue'
const handleOpen = (key: string, keyPath: string[]) => {
  console.log(key, keyPath)
}
const handleClose = (key: string, keyPath: string[]) => {
  console.log(key, keyPath)
}
</script>


<style>
.tac {
  width: 17vw;
}
</style>
